home *** CD-ROM | disk | FTP | other *** search
- Path: dawn.mmm.com!news
- From: kjhopps@mmm.com (Kevin J Hopps)
- Newsgroups: comp.lang.c++
- Subject: Re: Help on assignment
- Date: 22 Feb 1996 22:16:27 GMT
- Organization: 3M - St. Paul, MN 55144-1000 US
- Message-ID: <4gipvr$4ft@dawn.mmm.com>
- References: <4gdmjm$1kr@cloner4.netcom.com> <4gef32$6g7@reader2.ix.netcom.com>
- Reply-To: kjhopps@mmm.com
- X-Newsreader: TIN [version 1.2 PL2]
-
- regmia@ix.netcom.com wrote:
- > dc30@ix.netcom.com(Diane Cogswell ) wrote:
-
- > >I'm hoping someone out there can help me out. I just started c++ and
- > >I'm having problems with a couple assinments. Don't think I recieved
- > >enough information.
- > >The first one:
- > >Write a function that normally takes one argument, the address of a
- > >string, and prints that string once. However, if a second, type int
- > >argument is provided and is greater than zero, the function prints the
- > >string the number of times equal to the number of times indicated.
-
- > >Second one is
- > >Write a function called zerosmaller that is passed to two int arguments
- > >by reference and then sets the smaller of the two numbers to 0. Write a
- > >main() program to exercise this function and print out the result.
- > >I would really appreciate any help anyone can give me. I understood
- > >Pascal but I'm having trouble trying to translate programs in c++.
- > >Thanks
- > > from discouraged
-
-
- > Ok you declare your first function like so:
-
- > void printstring(char *thestring, int count = 0);
-
- Doing somebody's homework for them robs them of the learning they might
- otherwise have received.
- --
- Kevin J. Hopps e-mail: kjhopps@mmm.com
- 3M Company phone: (612) 737-4643
- 3M Center, Bldg. 235-2D-57 fax: (612) 737-2700
- St. Paul, MN 55144-1000 Opinions are my own. I don't speak for 3M.
- But 3M speaks for me -- I did not write the following line:
-
- Opinions expressed herein are my own and may not represent those of 3M.
-